#include "tools.hpp"

#include <cstdio>
#include <string>

std::string getNumBinary(int a)
{
    std::string binary;
    binary.reserve(32);
    for (int i = 31; i >= 0; i--) {
        char c = ((a & (1 << i)) != 0) ? '1' : '0';
        binary.push_back(c);
    }
    return binary;
}

int main()
{
    lxj::Time time;

    auto s = getNumBinary(-15);
    std::puts(s.c_str());

    return 0;
}